package com.wyy.springcloud.sevice.impl;

import com.wyy.springcloud.dao.DeptDao;
import com.wyy.springcloud.pojo.Dept;
import com.wyy.springcloud.sevice.DeptService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DeptServiceImpl implements DeptService {

    @Autowired
    private DeptDao deptDao;

    public boolean addDept(Dept dept) {
        return deptDao.addDept(dept);
    }

    public Dept queryDeptById(Long deptno) {
        return deptDao.queryDeptById(deptno);
    }

    public List<Dept> queryDeptAll() {
        return deptDao.queryDeptAll();
    }
}
